package com.ay277.htqoa.event.biz.impl;

import com.ay277.htqoa.base.biz.BaseBiz;
import com.ay277.htqoa.base.dao.Dao;
import com.ay277.htqoa.event.biz.EventBiz;
import com.ay277.htqoa.event.dao.EventDao;
import com.ay277.htqoa.event.entity.Event;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * Created by Temptation on 2016/12/20.
 */
@Service
@Transactional
public class EventBizImpl extends BaseBiz<Event,String> implements EventBiz{
    @Override
    @Autowired
    @Qualifier("eventDaoImpl")
    public void setDao(Dao<Event, String> dao) {
        super.setDao(dao);
    }

    @Override
    public List<Event> findEvent(String start, String end) {
        EventDao eventDao= (EventDao) getDao();
        return eventDao.selectEvent(start,end);
    }
}
